package com.wehealth.adapter;

import java.util.List;

import com.wehealth.R;
import com.wehealth.dm.DM_Questionnaire_page2_item;
import com.wehealth.dm.DM_Questionnaire_page3_item;

import android.content.Context;
import android.util.Log;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.BaseAdapter;
import android.widget.CheckBox;
import android.widget.CompoundButton;
import android.widget.RadioButton;
import android.widget.RadioGroup;
import android.widget.RadioGroup.OnCheckedChangeListener;
import android.widget.TextView;

public class Adapter_questionnaire_page4_result extends BaseAdapter{
	
	private Context ctx;
	private List<String> mList;
	
	
	public Adapter_questionnaire_page4_result(Context context,List<String>mList ){
		ctx =context;
		this.mList =mList;
	}

	@Override
	public int getCount() {
		// TODO Auto-generated method stub
		return mList.size();
	}

	@Override
	public Object getItem(int pos) {
		// TODO Auto-generated method stub
		return pos;
	}

	@Override
	public long getItemId(int pos) {
		// TODO Auto-generated method stub
		return pos;
	}

	@Override
	public View getView(int pos, View arg1, ViewGroup arg2) {
		// TODO Auto-generated method stub
		View view = LayoutInflater.from(ctx).inflate(R.layout.questionnaire_page4_list_item_result,null);
		TextView   result =(TextView)view.findViewById(R.id.result_str);
		String result_item = mList.get(pos);
		Log.d("SIMMON","    pos="+pos);
		Log.d("SIMMON","    result_item="+result_item);
		result.setText(result_item);
		return view;
	}
		
}
